{% extends 'myadmin/base.html' %}
{%block body%}
<div class="tpl-content-wrapper">
        <div class="tpl-content-page-title">
            Amaze UI 表单
        </div>
        <ol class="am-breadcrumb">
            <li><a href="#" class="am-icon-home">首页</a></li>
            <li><a href="#">表单</a></li>
            <li class="am-active">Amaze UI 表单</li>
        </ol>
        <div class="tpl-portlet-components">
            <div class="portlet-title">
                <div class="caption font-green bold">
                    <span class="am-icon-code"></span> 表单
                </div>
                <div class="tpl-portlet-input tpl-fz-ml">
                    <div class="portlet-input input-small input-inline">
                        
                    </div>
                </div>


            </div>

            <div class="tpl-block" style="height:600px">

                <div class="am-g" >
                    <div class="tpl-form-body tpl-form-line">
                        <form action="{% url 'myadmin_addcategory' %}" class="am-form tpl-form-line-form" method="post" enctype="multipart/form-data">
                        {% csrf_token %}

                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">选择分类
                                <span class="tpl-form-line-small-title">Title</span>
                            </label>
                            <div class="am-u-sm-9">
                                <select name="pid" data-am-selected="{btnSize: 'sm'}" style="display: none;">
                                    <option  value="0">顶级类别</option>
                                    {% for i in cates %}
                                    <option  value="{{i.id}}">{{i.newname}}{{i.cname}}
                                    </option>

                                    {% endfor %}
                                  
                                </select>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label for="cate-name" class="am-u-sm-3 am-form-label">分类
                                <span class="tpl-form-line-small-title">Title</span>
                            </label>
                            <div class="am-u-sm-9">
                                <input type="text" name="name" class="tpl-form-input" id="cate-name" placeholder="请输入标题文字">
                                </div>
                        </div>

                        
                        
                        <div class="am-form-group">
                            <div class="am-u-sm-9 am-u-sm-push-3">
                                <button  class="am-btn am-btn-primary tpl-btn-bg-color-success ">提交</button></div>
                        </div>
                    </form>

                    </div>
                </div>
            </div>


        </div>

    </div>
{%endblock%}